<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="js/vue.js"></script>
</head>
<body>
    <div id="app"></div>
    
</body>
</html>
<script>
    new Vue({
        el:'#app',
        data(){
            return {
                
            }
        },
        
        beforeCreate(){
            console.log('beforeCreate');
        },
        created(){
            console.log('created');
            //关注改在完成  一般向后台发送请求  初始化操作
            //发送ajax请求到服务器
        },
        beforeMount(){
            console.log('beforeMount');
        },     
        mounted(){
            console.log('mounted');
        },
        beforeUpdate(){
            console.log
        },
        updated(){
            console.log('updated');
        },
        beforeDestroy(){
            console.log('beforeDestroy');
            //销毁之前  做一些释放资源的首尾工作
        },
        destroyed(){
            console.log('destroyed');
        },
    });
</script>